﻿
@using Newtouch.Infrastructure.Enum
@{
    ViewBag.Title = "修改有效期";
    Layout = "~/Views/Shared/_Form.cshtml";

}

<form id="form1">
    <div class="container" style="padding:0;">
        <div class="tab-content" style="margin-top:10px;padding-right:10px;">
            <div role="tabpanel" class="tab-pane fade in active">
                <table class="form">
                    <tr>
                        <th class="formTitle">有效期：</th>
                        <td class="formValue" style="width:180px;padding-right:50px;">
                            <input id="yxq" type="text" class="form-control input-wdatepicker" style="width:50%; float:left;" onfocus="WdatePicker({ dateFmt: 'yyyy-MM-dd HH:mm:ss' })" />
                        </td>

                    </tr>

                </table>
            </div>
        </div>
    </div>
</form>


<script lang="javascript">
    var kcId = $.request("kcId");
    var yxq = $.request("yxq");
    $("#yxq").val(yxq);

    //保存
    function SubmitForm() {
        if (!DataValidate()) {
            return;
        }
        var postData = $("#form1").formSerialize();
        postData.kcId = kcId;
        postData.yxq = $("#yxq").val();
        return postData;
    }

    //数据效验
    function DataValidate() {
        if ($("#yxq").val() === "") {
            $.modalAlert("有效期必填", 'warning');
            return false;
        }
        return true;
    }


</script>